package com.itheima.dao;


import com.itheima.pojo.DishFlavor;
import com.itheima.pojo.SetMealDishes;
import com.itheima.vo.DishListVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author itheima
 * @since 2022-05-03
 */
@Mapper
public interface SetMealDishesMapper {
    /**
     * 添加
     *
     * @param dishesList
     * @return
     */
    int insert(@Param("list") List<SetMealDishes> dishesList);

    /**
     * 根据id查询
     *
     * @param id
     * @return
     */
    List<SetMealDishes> selectById(@Param("setMealId") String id);

    /**
     * 根据菜品id逻辑删除
     *
     * @param ids
     * @return
     */
    int updateIsDeletedById(String[] ids);

    /**
     * 根据菜品id逻辑删除
     * @param setmealId
     * @return
     */
    int deleteBySetMealId(@Param("setmealId") String setmealId);

    /**
     * 口味下拉
     *
     * @param dishId
     * @return
     */
    List<DishFlavor> selectByDishId(String dishId);




}
